<template>
    <div class="main_bbox">
        <el-dialog title="授权书" center :visible.sync="open" append-to-body>
            <!-- <el-table :data="gridData">
                <el-table-column property="date" label="日期" width="150"></el-table-column>
                <el-table-column property="name" label="姓名" width="200"></el-table-column>
                <el-table-column property="address" label="地址"></el-table-column>
            </el-table> -->
            <p style="text-indent: 2em;">
                本人同意将本人已发表的内容的数字化复制权、发行权、信息网络传播权、翻译权、汇编权授权给中医药文化传播协同服务平台，该平台可通过PC端、手机移动端、智慧终端大屏、站点等各种载体、端口、渠道传播。授权使用报酬及领取方式如下:
                (请选择其中一种)。</p>
            <div>
                <el-radio v-model="radio" label="1">授权下载(按照中医药文化传播协同平台公布的授权模板和创作标准领取报酬。)</el-radio>
                <el-radio v-model="radio" label="2" style="margin-top: 15px;">开放下载( 向社会公众免费开放的免费授权。 )</el-radio>
            </div>
            <p>授权使用期限：著作权保护期限。</p>
            <p>授权使用范围：全球范围。</p>
            <div>
                <div class="btm_names">作者签字：<span>{{ $store.state.user.nickName }}</span></div>
                <div  class="btm_names">{{ getFormattedDate() }}</div>
            </div>
            <div slot="footer" style="margin-bottom: 50px;" class="dialog-footer">
                <!-- <el-button @click="cancel">取 消</el-button> -->

                <el-button size="medium " type="primary" @click="submit">提交授权书</el-button>
            </div>
        </el-dialog>

    </div>
</template>

<script>

export default {
    props: ['isNotice'],
    data() {
        return {
            radio: '1',
            gridData: [{
                date: '2016-05-02',
                name: '王小虎',
                address: '上海市普陀区金沙江路 1518 弄'
            }, {
                date: '2016-05-04',
                name: '王小虎',
                address: '上海市普陀区金沙江路 1518 弄'
            }, {
                date: '2016-05-01',
                name: '王小虎',
                address: '上海市普陀区金沙江路 1518 弄'
            }, {
                date: '2016-05-03',
                name: '王小虎',
                address: '上海市普陀区金沙江路 1518 弄'
            }],
        }
    },
    created() { },
    methods: {
        getFormattedDate() {
            var date = new Date();
            var year = date.getFullYear();
            var month = ("0" + (date.getMonth() + 1)).slice(-2); // Months are zero-based, add leading zero  
            var day = ("0" + date.getDate()).slice(-2); // Add leading zero for single-digit days  

            return year + "-" + month + "-" + day;
        },
        submit() {
            //请求后台这里
            this.$emit('updateProps', false)
            this.$emit('shouquan', this.radio)
            //this.$router.push({path:'/content/chugao'})
        },
        cancel() {

            this.$emit('updateProps', false)
        },

    },
    computed: {
        open: {
            get() {
                return this.isNotice
            },
            set() {
                this.$emit('updateProps', false)
            }
        }
    }
}
</script>

<style lang='scss' scoped>
.main_bbox {
    font-size: 16px;
    font-family: Microsoft YaHei, Microsoft YaHei;
    font-weight: 400;
    color: #3D3D3D;
    line-height: 24px;

   
}
.btm_names {
        display: flex;
        // flex-direction: column;
        justify-content: flex-end;
        //  align-content: end;
        padding-right: 30px;
        padding-bottom: 10px;
    }
</style>